import { Injectable } from '@angular/core';
import {RequestUtil} from "../../../util/request-util";
import {Observable} from "rxjs/Observable";
import {MsgResult} from "../../../models/msg-result";
import {API} from "../../../constants/constants";

@Injectable()
export class LoginService {

  constructor(
    private requestUtil : RequestUtil
  ) { }


  loginLogDetails(id:string):Observable<MsgResult>{
    return this.requestUtil.get(API.getLoginLogById+'/'+id+'?format=json')
  }

  loginLogDelete(loginIdArr):Observable<MsgResult>{
    let params='loginIdArr='+loginIdArr;
    return this.requestUtil.post(API.deleteLoginLogs,params);
  }

}
